home *** CD-ROM | disk | FTP | other *** search
- global goBoss, goDotMan, gsColon, goOSMgr, gsNewName, gzActType, gnetID1, gNetLoadedCast
-
- on startMovie
- clearGlobals()
- gsColon = GetPathDelimiter()
- goOSMgr = new(script("Class OSMgr"))
- vsChapter = VOID
- if getRunMode(goOSMgr) = #Browser then
- if not voidp(externalParamName("sw1")) then
- vsActType = externalParamValue("sw1")
- gnetID1 = VOID
- gsNewName = "@" & gsColon & "dswmedia" & gsColon & vsActType & getFileExtension(goOSMgr, #cast)
- gNetLoadedCast = preloadNetThing(gsNewName)
- vzActType = symbol(vsActType)
- else
- gnetID1 = getNetText("javascript:getActCast()")
- end if
- if not voidp(externalParamName("sw2")) then
- vsChapter = externalParamValue("sw2")
- end if
- mCreateBoss(vzActType, vsChapter)
- else
- vzActType = #test
- castLib("evaluation").fileName = "@" & gsColon & "dswmedia" & gsColon & string(vzActType) & getFileExtension(goOSMgr, #cast)
- vsChapter = VOID
- mCreateBoss(vzActType, vsChapter)
- startMod()
- go(2)
- end if
- end
-
- on evalScript xsParam
- cursor(0)
- case xsParam of
- "donePrint":
- mDonePrint(goBoss)
- end case
- end
-
- on mCreateBoss xzActType, xsChapter
- goDotMan = new(script("DotManagerParent"), [#firstDotSprite: 1, #numDots: 90])
- if xzActType = #test then
- viNumQuestions = 20
- else
- viNumQuestions = 20
- end if
- goBoss = new(script("quizParent"), goDotMan, xzActType, viNumQuestions, xsChapter)
- end
-
- on startMod
- vlInfo = [#numAvailable: 35, #numChapters: 26]
- mInit(goBoss, vlInfo)
- end
-
- on stopMovie
- the actorList = []
- if getRunMode(goOSMgr) = #Authoring then
- castLib("evaluation").fileName = "@" & gsColon & "dswmedia" & gsColon & "eval.cst"
- end if
- mResetDots(goDotMan)
- end
-
- on ExternalCastExistP xsType
- vbFoundCast = 1
- vsCast = xsType
- vsColon = getColon(goOSMgr)
- vsNewName = "@" & vsColon & "dswmedia" & vsColon & vsCast & getFileExtension(goOSMgr, #cast)
- castLib("CurActCast").fileName = vsNewName
- return vbFoundCast
- end
-
- on checkNetStuff
- vbReady = 0
- if not voidp(gnetID1) then
- if netDone(gnetID1) then
- vsActCastName = netTextResult(gnetID1)
- if not voidp(vsActCastName) then
- if vsActCastName <> EMPTY then
- ExternalCastExistP(vsActCastName)
- vbReady = 1
- end if
- end if
- end if
- else
- if netDone(gNetLoadedCast) then
- castLib("evaluation").fileName = gsNewName
- vbReady = 1
- end if
- end if
- if vbReady then
- startMod()
- go(2)
- else
- go(the frame)
- end if
- end
-